package com.celesea.sso.user.dao;

import com.celesea.framework.authority.AuthorityGroup;
import com.celesea.framework.authority.AuthorityPoint;
import com.celesea.framework.authority.AuthorityRole;
import com.celesea.framework.dao.BaseDao;
import com.celesea.sso.user.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author JackYuan
 * @create 2017-11-08 21:25
 */
public interface UserDao extends BaseDao<User> {
    /**
     * 查询用户的角色集合
     *
     * @param user
     * @return
     */
    List<AuthorityRole> selectUserOfRoles(@Param("user") User user);

    /**
     * 查询用户的权限集合
     *
     * @param user
     * @return
     */
    List<AuthorityPoint> selectUserOfPoints(@Param("user") User user);

    /**
     * 查询用户的群组集合
     *
     * @param user
     * @return
     */
    List<AuthorityGroup> selectUserOfGroups(@Param("user") User user);
}
